s = input().split(" ")
a = int(s[0])
b = int(s[1])
if a > b:
    a, b = b, a
if b % a == 0:
    print(b)
else:
    i = 2
    j = 2
    while True:
        if a * i < b * j:
            i += 1
        elif a * i > b * j:
            j += 1
        else:
            print(a * i)
            break